package com.wwl.cms.utils.designModeTest.facade;

/**
 * @author wwl
 * @version 1.0
 * @date 2021/9/7 19:44
 * @description:
 */
public class HomeTheaterFacade {
    private DVDPlayer dvdPlayer;
    private Popcorn popcorn;

    public HomeTheaterFacade() {
        this.dvdPlayer = DVDPlayer.getInstance();
        this.popcorn = Popcorn.getInstance();
    }

    public void ready(){
        popcorn.on();
    }
    public void play(){
        dvdPlayer.on();
    }

    public void end(){
        popcorn.off();
        dvdPlayer.off();
    }

}
